﻿using System;
using Microsoft.EntityFrameworkCore.Migrations;

namespace BlogDemo.Infrastructure.Migrations
{
    public partial class initialize : Migration
    {
        protected override void Up(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.CreateTable(
                name: "Post",
                columns: table => new
                {
                    Id = table.Column<int>(nullable: false)
                        .Annotation("Sqlite:Autoincrement", true),
                    Title = table.Column<string>(maxLength: 20, nullable: false),
                    Body = table.Column<string>(maxLength: -1, nullable: false),
                    Author = table.Column<string>(maxLength: 10, nullable: false),
                    LastModifyTime = table.Column<DateTime>(nullable: false, defaultValue: new DateTime(2018, 8, 22, 10, 55, 53, 503, DateTimeKind.Local))
                },
                constraints: table =>
                {
                    table.PrimaryKey("PK_Post", x => x.Id);
                });
        }

        protected override void Down(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.DropTable(
                name: "Post");
        }
    }
}
